package cn.wolfcode.qo;

import cn.wolfcode.util.AllMsgEnum;
import lombok.Getter;
import lombok.Setter;
import org.springframework.format.annotation.DateTimeFormat;
import org.springframework.stereotype.Service;

import java.util.Date;

@Getter
@Setter
public class AllMsgQueryObject extends QueryObject {
     private Integer   business;
     private Integer isAppointment;
     @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
     private Date startTime;
     @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
     private Date endTime;
     private Integer type;

     private String names = AllMsgEnum.BUSINESS.name();


     public String getName(){
          return AllMsgEnum.valueOf(this.names).getSql();
     }
}
